import request from '@/request/index.js';

/*
检查检验订单分页查询
*/
export function getInspectList(params) {
	return request.get({
		url: '/app-api/hospital/order-inspection/list',
		params: params || {},
		custom: {
			title: "检查检验订单分页查询",
			authentication: true
		}
	});
}
/*
检查检验订单详情
*/
export function getInspectDetails(params) {
	return request.get({
		url: '/app-api/hospital/order-inspection/get-by-id',
		params: params || {},
		custom: {
			title: "检查检验订单详情",
			authentication: true
		}
	});
}
/*
检查检验订单去支付
*/
export function inspectOrderPay(params) {
	return request.post({
		url: '/app-api/hospital/order-inspection/wait-pay',
		params: params || {},
		custom: {
			title: "检查检验订单去支付",
			authentication: true
		}
	});
}

/*
检查检验预约项目获取
*/
export function getInspectType(params) {
	return request.get({
		url: '/app-api/hospital/inspection/list-patient',
		params: params || {},
		custom: {
			title: "预约检查检验自主开单项目",
			authentication: true
		}
	});
}
/*
检查检验自主开单提交
*/
export function inspectOrderSubmit(params) {
	return request.post({
		url: '/app-api/hospital/inspection/self-add',
		data: params || {},
		custom: {
			title: "检查检验自主开单提交",
			authentication: true
		}
	})
}

// 查询余额
export function getAccountBalance(params) {
	return request.get({
		url: '/app-api/hospital/service/query-balance',
		params: params || {},
		custom: {
			title: "获得账户余额",
			authentication: true
		}
	});
}

// 门诊缴费
export function servicePay(data) {
	return request.post({
		url: '/app-api/hospital/service/patient-pay',
		data: data || {},
		custom: {
			title: "门诊缴费",
			authentication: true
		}
	});
}

// 取消检查检验
export function cancelOrder(params) {
	return request.get({
		url: '/app-api/hospital/order-inspection/cancel-self-inspection',
		params: params || {},
		custom: {
			title: "取消检查检验",
			authentication: true
		}
	});
}